<template>
  <div class="welcome">
    
    <div class="container">
      <h1>MarkPad</h1>
      <p>简单排版,短时编辑,即时发布</p>
      <transition name="el-zoom-in-center">
      <el-button v-if="!started" @click="start">开&nbsp;始</el-button>
      </transition>
      <transition name="el-fade-in"> -->
      <Login v-if="started"></Login>
      </transition>
    </div>
  </div>
</template>


<script>
import Login from "@/views/Login";

export default {
  name: "welcome",
  components: {
    Login
  },
  data() {
    return {
      started: false
    };
  },
  methods: {
    start() {
      this.started = true;
    }
  }
};
</script>

<style lang="scss" scoped>
$bgc: #00bfff;
$dbWidth: 1366;
$dbHeight: 768;

@mixin calu-vw($inputWidth) {
  width: ($inputWidtch/$dbWidth) * 100 + vw;
}
@mixin calu-vh($inputHeight) {
  height: ($inputHeight/$dbHeight) * 100 + vh;
}

.welcome {
  position: fixed;
  width: 100%;
  height: 100%;
  background: $bgc;
  text-align: center;
  .container {
    width: 42%;
    margin: 10% auto;
    color: #fff;
    h1 {
      margin: 0;
      margin-bottom: 62px;
      font-size: 88px;
      font-weight: normal;
    }
    p {
      margin: 0;
      margin-bottom: 48px;
      font-size: 38px;
      font-weight: 300;
    }
    .el-button {
      margin: 0;
      padding: 14px 43px;
      border-radius: 6px;
      font-size: 26px;
      color: #0099ff;
      font-weight: 300;
    }
    @media screen and (max-width: 768px) {
      &{
        width: 70%;
        margin-top: 40%;
      }
      h1 {
        font-size: 40px;
        margin-bottom: 32px;
      }
      p {
        font-size: 20px;
        margin-bottom: 24px;
      }
      .el-button {
        padding: 10px 20px;
        font-size: 16px;
        text-align: center;
      }
    }
  }
}
</style>
